using System.Linq;

namespace Framework
{
    public static class Log
    {
        private static string BuildMessage(params object[] messages)
        {
            return messages.Aggregate("", (current, message) => current + (" - " + message));
        }

        // TODO [Conditional("DEBUG")]
        public static void Debug(params object[] messages)
        {
            UnityEngine.Debug.Log(BuildMessage(messages));
        }

        public static void Warn(params object[] messages)
        {
            UnityEngine.Debug.LogWarning(BuildMessage(messages));
        }

        public static void Error(params object[] messages)
        {
            UnityEngine.Debug.LogError(BuildMessage(messages));
        }
    }
}